#ifndef __RAW_PARASER_H_INCLUDED__
#define __RAW_PARASER_H_INCLUDED__

#include "common.h"
#include "packet_handler.h"
#include <netinet/ip.h>

#ifdef __cplusplus
extern "C" {
#endif

/**
 * 解析报文入口
 */
void parase(int fd);

int paraseRaw(char * buf, packet_handler* callback);

void print_app_buffer(char* ptr, unsigned len);

/**
 * 增加转发会话
 */
void add_forward_session(unsigned int src_addr,
		unsigned short src_port,
		unsigned int dst_addr,
		unsigned short dst_port);

#ifdef __cplusplus
}
#endif

#endif // __RAW_PARASER_H_INCLUDED__
